#!/usr/bin/env bash

set -ve

export LFS='/mnt/lfs'

_USER=`whoami`
if [ "$_USER" != "lfs" ];
then
    echo 'WARNING: User lfs ONLY!!!' && exit;
fi

############################# Linux API #############################

cd $LFS/sources/
rm -rf linux-4.20.12/
tar -xvf linux-4.20.12.tar.xz
cd linux-4.20.12/

mkdir -pv /tools/include

make mrproper

make INSTALL_HDR_PATH=dest headers_install
cp -rv dest/include/* /tools/include
